#include "../include/thread_pool.h"

int threadPoolInit(threadPool_t *pThreadPool, int workernum) {
    tidArrInit(workernum, &pThreadPool->tidArr);
    taskQueueInit(&pThreadPool->taskQueue);
    pthread_mutex_init(&pThreadPool->mutex, NULL);
    pthread_cond_init(&pThreadPool->cond, NULL);
    pThreadPool->exitFlag = 0;
    return 0;
}



